home *** CD-ROM | disk | FTP | other *** search
/ Amiga Collections: MegaDisc / MegaDisc 27 (1992-03)(MegaDisc Digital Publishing)(AU)(Disk 2 of 2).zip / MegaDisc 27 (1992-03)(MegaDisc Digital Publishing)(AU)(Disk 2 of 2).adf / Programming / Integer_Math / IntMath.Doc / IntMath.Doc
Text File  |  1992-03-30  |  3KB  |  93 lines

  1.  
  2.  
  3.                           INTEGER MATH ROUTINES  
  4.  
  5.  
  6.    All code and documentation (C) 1992 by Peter Thompson.
  7.  
  8.  
  9.    (( 27 )) (( 27 )) (( 27 )) (( 27 )) (( 27 )) (( 27 )) (( 27 )) (( 27 ))
  10.  
  11.  
  12.   This distribution is numbered 1 (one) and is dated 26th Jan. 1992
  13.  
  14. How?
  15. ~~~~
  16. These routines are "wareware";
  17.   1) Use at your own risk (beware the fruminous semantic error!).
  18.   2) If you do use them, send me a copy of the program you use them in.
  19.   3) You may freely redistribute the source under the following conditions;
  20.     a) *Nothing* is altered in or omitted from the code or documentation;
  21.     b) Copyright remains solely mine.
  22.   4) You may charge a fee for passing on this code, but you may not prevent
  23.   anyone else from charging any other fee for performing that same service.
  24.   (Translation : you can sell this code, but you can't stop anyone else
  25.   selling it for less (or even giving it away (or even paying other people
  26.   to take it (unlikely as that may seem)))).
  27.  
  28. What?
  29. ~~~~~
  30.   The routines in this drawer can be divided into four classes;
  31.  
  32.   a) 32 bit integer math (Int32.i)
  33.  
  34.      Just your standard 32 bit multiply, square, signed & unsigned divide
  35.   routines. Caveat: no overflow detection.
  36.  
  37.   b) 64 bit integer math (Int64.i)
  38.  
  39.      Just your standard 64 bit multiply, square, signed & unsigned divide
  40.   routines. Caveat: no overflow detection.
  41.  
  42.   c) 32<->64 bit math (LongInts.i)
  43.  
  44.      These routines are intended for use with 32-bit fixed point arithmetic.
  45.   They produce 64 bit results which can then be shifted and truncated to
  46.   produce 32-bit results.
  47.  
  48.   d) 64<->128 bit math (LongInts.i)
  49.  
  50.      Much the same as for the 32<->64, except read "64" for "32", and "128"
  51.   for "64".
  52.  
  53.   For further information, consult the routines themselves.
  54.  
  55. Why?
  56. ~~~~
  57.   Because I wanted to. I have been toying with the idea of writing (yet
  58.   another) Mandelbrot/Julia generator for a while now; an idea made more
  59.   realistic by my recent registration for DICE (matt Dillon's Integrated C
  60.   Environment - see review this issue) for the magnificent sum of US$50.
  61.   However, in the interim, too many other generators have come out; so,
  62.   rather than waste the sustained burst of inspiration that lead to the
  63.   creation of these routines, I decided to send the creations of my hands
  64.   forth into an appreciative world.
  65.  
  66. What next?
  67. ~~~~~~~~~~
  68.   * 68020/030/040 support. These processors have 32x32->64 bit multiply
  69.   instructions, thus allowing shorter and faster code. Due: when I can
  70.   afford a A3000UX with an 040 card ;-).
  71.  
  72.   * Unlimited length math routines. Due: when I feel like it.
  73.  
  74.   * 128x128->256 bit routines... Due: when I have nothing better to do.
  75.  
  76.   * Fix-point routines (math, input, output). Due: sometime mid 1992.
  77.  
  78.    * C glue routines. Due: Whenever I can be bothered. Probably when I next
  79.   run out of stuff to send to MegaDisc.
  80.  
  81. Where?
  82. ~~~~~~
  83.   Peter Thompson
  84.   33 Pleasant Street
  85.   Pascoe Vale 3044
  86.   AUSTRALIA
  87.  
  88.  
  89.    (( 27 )) (( 27 )) (( 27 )) (( 27 )) (( 27 )) (( 27 )) (( 27 )) (( 27 ))
  90.  
  91.  
  92.  
  93.